#coding=utf-8

import requests
from bs4 import BeautifulSoup
import ssl
ssl._create_default_https_context = ssl._create_unverified_context



movie_url = 'http://oln.oubolan.cn'

def download_page(url):
    headers = {
        'User-Agent':'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_12)AppleWebKit/537.36 (KHTML, like Gecko) Chrome/47.0.2526.80 Safari/537.36'
    }

    data = requests.get(url, headers = headers, verify=False).content
    return data

def paser_html(html):
    soup = BeautifulSoup(html, 'lxml')
    title = soup.find(property = 'v:itemreviewed').string

    return title

def main():
    print(paser_html(download_page(movie_url)))
    print("ddddd")

if __name__ == '__main__':
    main()
